<template>
  <div class="box">
    <h1>App根组件</h1>
    <!-- <svg-icon name="lock" color="blue" width="100px" height="100px"></svg-icon> -->
    <!-- 测试全局组件 -->
    <Pagination></Pagination>
    <svg-icon name="lock" color="blue" width="100px" height="100px"></svg-icon>
    <h1>测试axios的二次封装</h1>
  </div>

  <div>
    <h1></h1>
  </div>
</template>

<script setup lang="ts">
// import SvgIcon from '@/components/SvgIcon/SvgIndex.vue'
import request from '@/utils/request'
import { onMounted } from 'vue'
// 当组件挂载完毕测试发一个请求
onMounted(() => {
  request({
    url: '/user/login',
    method: 'post',
    data: {
      username: 'admin',
      password: '111111',
    },
  }).then((res) => {
    console.log(res)
  })
})
</script>

<style scoped lang="scss">
.box {
  width: 600px;
  height: 200px;
  background: rgb(226, 244, 202);
  h1 {
    //color: $color;
    color: $base-color;
  }
}
</style>
